<?php

$poll = $this->poll;

if (false != $poll) {
?>
<p><?php echo $this->escape($poll->question) ?></p>
<form action="/Blackbird/polls/vote/slug/<?php echo $this->escape($poll->slug) ?>" method="post">
	<ul>
<?php foreach ($poll->options as $option) { ?>
		<li>
			<input id="poll-option-<?php echo $option->pollOptionId ?>" type="radio" value="<?php echo $option->pollOptionId ?>" name="pollOptionId"/>
			<label for="poll-option-<?php echo $option->pollOptionId ?>"><?php echo $this->escape($option->answer) ?></label>
		</li>
<?php } ?>
	</ul>
	<p style="text-align:center"><button type="submit">Votar</button><br/>
		<a href="/Blackbird/polls/results/slug/<?php echo $this->escape($poll->slug) ?>">Ver resultados</a></p>
</form>
<?php } ?>